//// demo_prog/chapter6/lec9_2d_array_access.c
// 二维数组访问过程示例
#include <stdio.h>
int main(void)
{
    short a[3][4];
    // 让我们看一下数组的起始地址
    printf("Starting address of a is %lu.\n", (unsigned long)a);
    printf("Address of a[1][2] is %lu.\n", (unsigned long)&a[1][2]);
    // 计算一下a[1][2]相比数组起始地址a的偏移量
    unsigned long ulOffset = (unsigned long)&a[1][2] - (unsigned long)a;
    printf("Address offset of a[1][2] is %lu.\n", ulOffset);
    return 0;
}